package com.example.aidocengine.pojo.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import java.time.LocalDateTime;

@Data
@TableName("primary_device_terminology")
public class PrimaryDeviceTerminology {
    
    @TableId(type = IdType.AUTO)
    private Long id;
    
    private String deviceType;
    
    private String writingPrinciple;
    
    private String typicalExample;
    
    private String remark;
    
    private String validationMessage;
    
    private String initialState;
    
    private String targetState;
    
    /**
     * 父记录ID，用于建立层级关系
     */
    private Long parentId;
    
    /**
     * 是否为模板(1:设备类型模板 0:具体编写原则)
     */
    private Integer isTemplate;
    
    /**
     * 显示顺序
     */
    private Integer displayOrder;
    
    /**
     * 是否标记为删除(1:是 0:否)
     */
    private Integer isDeleted;
    
    private Integer status;
    
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createdTime;
    
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime updatedTime;
    
    // 手动添加getter和setter方法以确保编译通过
    public String getInitialState() {
        return initialState;
    }
    
    public void setInitialState(String initialState) {
        this.initialState = initialState;
    }
    
    public String getTargetState() {
        return targetState;
    }
    
    public void setTargetState(String targetState) {
        this.targetState = targetState;
    }
    
    public String getValidationMessage() {
        return validationMessage;
    }
    
    public void setValidationMessage(String validationMessage) {
        this.validationMessage = validationMessage;
    }
}